:root {
    --primary: #0d6efd;
    --muted: #6c757d;
    --bg: #f8fafc;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--bg);
    color: #222;
}

main {
    flex: 1;
}

.product-card {
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    border-radius: 0.6rem;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 1rem 2rem rgba(18, 38, 63, 0.08) !important;
}

.product-img {
    height: 220px;
    object-fit: cover;
}

.card .btn[title] { cursor: pointer; }

/* Product detail page */
.product-detail-gallery {
    border-radius: 1rem;
}

.product-detail-image-wrap {
    position: relative;
    aspect-ratio: 1 / 1;
    background: linear-gradient(145deg, #f8fafc 0%, #eef2f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-detail-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 1.5rem;
    transition: transform 0.35s ease;
}

.product-detail-gallery:hover .product-detail-image {
    transform: scale(1.03);
}

.product-detail-ribbon {
    position: absolute;
    top: 1rem;
    left: 1rem;
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.product-detail-title {
    font-size: clamp(1.5rem, 3vw, 2rem);
    line-height: 1.25;
    color: #1a1d21;
}

.product-detail-price {
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--primary);
    letter-spacing: -0.02em;
}

.product-detail-stock .letter-spacing-sm {
    letter-spacing: 0.06em;
}

.product-qty-group {
    width: 140px;
}

.product-qty-group .qty-input {
    max-width: 3.5rem;
    -moz-appearance: textfield;
}

.product-qty-group .qty-input::-webkit-outer-spin-button,
.product-qty-group .qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.product-detail-btn-cart {
    border-radius: 0.75rem;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(13, 110, 253, 0.25);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.product-detail-btn-cart:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(13, 110, 253, 0.35);
}

.product-detail-tabs .nav-link {
    white-space: nowrap;
    font-weight: 500;
    color: var(--muted);
}

.product-detail-tabs .nav-link.active {
    background: var(--primary);
    color: #fff;
}

.product-detail-specs dt {
    font-size: 0.9rem;
}

.product-detail-related .product-img {
    height: 180px;
}

@media (max-width: 991.98px) {
    .product-detail-image-wrap {
        aspect-ratio: 4 / 3;
    }

    .product-detail-actions .product-detail-cart-form .col {
        flex: 1 1 100%;
    }

    .product-qty-group {
        width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 575.98px) {
    .product-detail-trust small {
        font-size: 0.7rem;
    }

    .product-detail-related .product-img {
        height: 140px;
    }
}

.bg-soft {
    background-color: #f8fafc;
}

.text-truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Navbar search */
.navbar .form-control {
    min-height: 44px;
}

/* Site footer — modern premium dark */
:root {
    --footer-primary: #2563eb;
    --footer-bg: #0f172a;
    --footer-muted: #94a3b8;
    --footer-heading: #f8fafc;
    --footer-border: rgba(148, 163, 184, 0.12);
}

.site-footer {
    position: relative;
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    color: var(--footer-muted);
    background: linear-gradient(180deg, #0f172a 0%, #020617 55%, #0f172a 100%);
    padding: clamp(3rem, 6vw, 4.5rem) 0 clamp(2rem, 4vw, 2.75rem);
    overflow: hidden;
    border-top: 1px solid var(--footer-border);
    box-shadow: 0 -24px 48px rgba(15, 23, 42, 0.45);
}

.site-footer__glow {
    position: absolute;
    top: -40%;
    right: -10%;
    width: min(70vw, 520px);
    height: min(70vw, 520px);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.22) 0%, transparent 70%);
    pointer-events: none;
}

.site-footer__inner {
    position: relative;
    z-index: 1;
}

.site-footer__grid {
    padding-bottom: 0.25rem;
}

.site-footer__brand {
    margin-bottom: 1rem;
    transition: opacity 0.3s ease;
}

.site-footer__brand:hover {
    opacity: 0.92;
}

.site-footer__logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.35), rgba(37, 99, 235, 0.12));
    border: 1px solid rgba(37, 99, 235, 0.45);
    color: #93c5fd;
    font-size: 1.25rem;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.site-footer__brand-name {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--footer-heading);
}

.site-footer__tagline {
    font-size: 0.95rem;
    font-weight: 600;
    color: #e2e8f0;
    margin-bottom: 0.5rem;
    max-width: 22rem;
    line-height: 1.5;
}

.site-footer__desc {
    font-size: 0.875rem;
    line-height: 1.65;
    color: var(--footer-muted);
    max-width: 22rem;
}

.site-footer__heading {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--footer-heading);
    margin-bottom: 1.25rem;
}

.site-footer__nav li + li {
    margin-top: 0.65rem;
}

.site-footer__nav a {
    display: inline-block;
    color: var(--footer-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.15rem 0;
    transition: color 0.3s ease, transform 0.3s ease;
}

.site-footer__nav a:hover {
    color: #fff;
    transform: translateX(4px);
}

.site-footer__contact li + li {
    margin-top: 0.85rem;
}

.site-footer__contact-link {
    display: inline-flex;
    align-items: flex-start;
    gap: 0.65rem;
    color: var(--footer-muted);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.3s ease;
}

.site-footer__contact-link i {
    color: var(--footer-primary);
    font-size: 1rem;
    margin-top: 0.1rem;
    flex-shrink: 0;
    transition: color 0.3s ease, transform 0.3s ease;
}

.site-footer__contact-link:hover {
    color: #e2e8f0;
}

.site-footer__contact-link:hover i {
    color: #60a5fa;
    transform: scale(1.08);
}

.site-footer__contact-static {
    display: inline-flex;
    align-items: flex-start;
    gap: 0.65rem;
    font-size: 0.875rem;
    color: var(--footer-muted);
}

.site-footer__contact-static i {
    color: var(--footer-primary);
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.site-footer__social-lead {
    font-size: 0.875rem;
    line-height: 1.55;
    color: var(--footer-muted);
    max-width: 16rem;
}

.site-footer__social {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.site-footer__social-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    color: #cbd5e1;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--footer-border);
    text-decoration: none;
    transition: color 0.3s ease, background 0.3s ease, border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.site-footer__social-btn:hover {
    color: #fff;
    background: rgba(37, 99, 235, 0.25);
    border-color: rgba(37, 99, 235, 0.55);
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(37, 99, 235, 0.22);
}

.site-footer__social-btn:focus-visible {
    outline: 2px solid var(--footer-primary);
    outline-offset: 2px;
}

.site-footer__divider {
    height: 1px;
    margin: clamp(2rem, 4vw, 2.75rem) 0 clamp(1.25rem, 3vw, 1.75rem);
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(148, 163, 184, 0.25) 20%,
        rgba(148, 163, 184, 0.35) 50%,
        rgba(148, 163, 184, 0.25) 80%,
        transparent 100%
    );
}

.site-footer__bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}

@media (min-width: 576px) {
    .site-footer__bottom {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

.site-footer__copy {
    font-size: 0.8125rem;
    color: #64748b;
    letter-spacing: 0.02em;
}

.site-footer__copy strong {
    color: #cbd5e1;
    font-weight: 600;
}

.site-footer__legal {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.75rem;
}

@media (min-width: 576px) {
    .site-footer__legal {
        justify-content: flex-end;
    }
}

.site-footer__legal a {
    font-size: 0.8125rem;
    color: var(--footer-muted);
    text-decoration: none;
    transition: color 0.3s ease;
}

.site-footer__legal a:hover {
    color: #fff;
}

.site-footer__dot {
    display: inline-block;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #475569;
    vertical-align: middle;
}

@media (max-width: 767.98px) {
    .site-footer__grid > [class*="col-"] {
        padding-top: 0.25rem;
        padding-bottom: 0.25rem;
    }
}

/* Checkout */
.payment-option {
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.payment-option:has(.form-check-input:checked) {
    border-color: var(--primary) !important;
    background-color: rgba(13, 110, 253, 0.06);
}

.payment-option .form-check-input {
    margin-top: 0.35rem;
}

/* Invoice print */
@media print {
    .no-print,
    header,
    footer,
    .navbar,
    .alert {
        display: none !important;
    }

    body {
        background: #fff !important;
    }

    main {
        padding: 0 !important;
    }

    .container {
        max-width: 100% !important;
        padding: 0 !important;
    }

    .invoice-card {
        box-shadow: none !important;
        border: 1px solid #dee2e6 !important;
    }
}

@media (max-width: 576px) {
    .product-img { height: 150px; }
}
